package com.x.gzcrm.service;



import com.github.pagehelper.PageInfo;
import com.x.gzcrm.model.Role;

import java.util.List;

/**
 * Role的service
 */
public interface IRoleService {
    public List<Role> findAllRoles();

    /**
     *
     * @param role
     * @param ids 权限id,多个权限用逗号分开(1,3,4,5)
     */
    public void save(Role role, String ids);

    public Role findByRoleId(Integer roleId);

    /**
     * 返回此角色的所有权限 id,用逗号拼接在一起
     * eg:1,3,34,3
     * @param roleId
     * @return
     */
    public String findPermissionIdsStrByRoleId(Integer roleId);

    public void delete(Integer roleId);

    public PageInfo<Role> findPageInfo(int page, int pageSize);
}
